<?php
include_once 'controller/default.php';
include_once 'model/questions/process.php';
    if(isset($_GET)){
        $question = new questions();
        if($_GET["menu"] == "questionunaccept"){
            $update = $question->UnAccept($_GET);
            if($update){
                echo '<script>alert("Hủy Question thành công.")</script>';
                include 'view/question/question_manager.php';
            }else{
                echo '<script>alert("Hủy Question thất bại.")</script>';
                include 'view/question/question_manager.php';
            }
        } else if($_GET["menu"] == "questiondelete"){
            $delete = $question->Delete($_GET);
            if($delete){
                echo '<script>alert("Xóa Question thành công.")</script>';
                include 'view/question/question_manager.php';
            }else{
                echo '<script>alert("Xóa Question thất bại.")</script>';
                include 'view/question/question_manager.php';
            }
        }
    }
?>